<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>微信支付配置</title>
  <meta name="renderer" content="webkit">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
	#parse('/headFiles.html')
</head>
<body>
<div class="layui-fluid">
   	<div class="layui-form" id="LAY-config-form" wid100>
		<input name="appId" type="hidden" value="$!{appId}">
		<div class="layui-row">
			<div class="layui-col-sm6">
				<div class="layui-form-item">
					<label class="layui-form-label">客服电话</label>
					<div class="layui-input-block">
						<input type="text" class="layui-input" name="serverPhone" value="$!{serverPhone}">
					</div>
				</div>
			</div>
		</div><!-- /.layui-row -->
	    <div class="layui-form-item layui-hide">
	    	<input type="button" lay-submit lay-filter="LAY-form-submit" id="LAY-form-submit" value="确认">
  		</div>
	</div>
</div>

#parse('/footFiles.html')
<script type="text/javascript">
layui.config({
  base: '$!{webRoot}/layuiadmin/'
}).extend({
  index: 'lib/index'
}).use(['index', 'form'],function (){
	var $ = layui.$,form = layui.form;

	form.on('select(tokenType)', function(data){
		if(data.value == 2){
			$('#http_config_panel').show();
		}else{
			$('#http_config_panel').hide();
		}
	});

	$('#accountGroupId').select2({
		placeholder: "请选择支付账号组",
		width: '300px',
		theme: 'bootstrap',
		allowClear : true,
		ajax: {
			url: '$!{webRoot}/config/account_group/select.data',
			method: 'post',
			delay: 250,
			processResults: function (result) {
				if (result.code == 200) {
					return {
						pagination: {more: result.body.more},
						results: result.body.data || []
					};
				} else {
					return {results: []};
				}
			}
		}
	});
});
</script>
</body>
</html>